package com.yueya.api.reservation;

import com.jfinal.aop.Duang;
import com.jfinal.kit.JsonKit;
import com.yueya.api.reservation.IReservationService;
import com.yueya.common.action.ApiController;
import com.yueya.common.model.Resp;

import net.sf.json.JSONObject;

/**
 * 咨询预约管理
 * 
 * @author 41654
 *
 */
public class IReservationController extends ApiController {

	// 添加登记记录
	public void save() {
		JSONObject jo = this.getJson();
		jo.put("userid", this.getUserId());
		Resp resp = Duang.duang(IReservationService.class).save(jo);
		renderJson(JsonKit.toJson(resp));
	}

	// 获取登记列表
	public void getPageList() {
		JSONObject jo = this.getJson();
		Resp resp = Duang.duang(IReservationService.class).getPageList(jo);
		renderJson(JsonKit.toJson(resp));
	}

}
